<?php
defined('_JEXEC') or die('Restricted access');
$db = JFactory::getDBO();
if(JRequest::getVar('user_id')){
	$query = "SELECT * FROM #__users WHERE id = ".JRequest::getVar('user_id');
	$db->setQuery($query);
	$user = $db->loadObject();
}
if(JRequest::getVar('pn')){
	
	$query = "SELECT * FROM #__users WHERE profile_number = '".JRequest::getVar('pn')."'";
	$db->setQuery($query);
	$user = $db->loadObject();
}
if($user->id){
?>
<style>
.pro_name_more {
    color: #B60800;
    font-size: 12px;
    font-weight: bold;
	border-bottom: 1px dotted #999999;
	padding: 5px 0 5px 5px;
}
.pro_nd_more{
	padding: 5px 0 5px 5px;
}
</style>
<div class="pro_name_more"><strong>User information</strong>:</div>
<div class="pro_nd_more">
	<strong>Name</strong>: <?php echo $user->name;?><br />
    <strong>Email</strong>: <?php echo $user->email;?> <br />
    <strong>Company</strong>: <?php echo $user->company;?> <br />
    <strong>Addres</strong>: <?php echo $user->address;?> <br />
    <strong>Postnr.</strong>: <?php echo $user->code;?> <br />
    <strong>City</strong>: <?php echo $user->city;?> <br />
    <strong>Phone</strong>: <?php echo $user->phone;?> <br />
	<strong>Cvr</strong>: <?php echo $user->cvr;?>
</div>
<?php } else {?>
<div class="pro_name_more"><strong>No information</strong>
<?php }?>